package com.example.rxjavalearn2.simple_rxjava;

/**
 * Description: 管理流程运行
 * Author: wucan
 * Date: 20-5-29 下午4:11
 */
public abstract class Obserable<T> implements ObservableSource<T>{



    public static <T> Obserable<T> creat(ObservableOnSubscribe<T> source ){

        return new ObservableCreat(source);
    }




    public abstract void subscirbeActual(Observer<T> observer);


    @Override
    public void subscribe(Observer<T> observer) {
        //ObservableCreat.subscirbeActual(observer)
        System.out.println("Obserable."+"subscribe");
        subscirbeActual(observer);
    }
}
